import { Button, Result } from 'antd'

const FormDelete = ({ data, ModalEvent, Off }) => {
    const onDelate = () => {
        ModalEvent.emit({ type: 'Delete', data })
        Off()
    }
    return (
        <Result
            status="warning"
            title="数据删除后将无法恢复,请确认后删除!"
            extra={[
                <Button type="primary" key="delete" size='large' danger onClick={onDelate}>确认删除!</Button>,
                <Button type="primary" key="cancel" size='large' onClick={Off}>取消</Button>
            ]}
        />
    )
};

export default FormDelete;